package com.stylefeng.guns.common.persistence.model;

import java.io.Serializable;

import com.baomidou.mybatisplus.enums.IdType;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author zhouh
 * @since 2017-10-17
 */
@TableName("biz_order_item")
public class OrderItem extends Model<OrderItem> {

    private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	private Integer id;
    /**
     * 订单号
     */
	@TableField("order_no")
	private String orderNo;
    /**
     * 产品id
     */
	private Integer pid;
    /**
     * 产品型号
     */
	@TableField("product_model")
	private String productModel;
    /**
     * 产品类型
     */
	@TableField("product_type")
	private Integer productType;

	/**
	 * 产品类型
	 */
	@TableField("product_type_name")
	private String productTypeName;


    /**
     * 单价
     */
	private Double price;
    /**
     * 数量
     */
	private Integer quantity;
    /**
     * 总价
     */
	private Double amount;


	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getOrderNo() {
		return orderNo;
	}

	public void setOrderNo(String orderNo) {
		this.orderNo = orderNo;
	}

	public Integer getPid() {
		return pid;
	}

	public void setPid(Integer pid) {
		this.pid = pid;
	}

	public String getProductModel() {
		return productModel;
	}

	public void setProductModel(String productModel) {
		this.productModel = productModel;
	}

	public Integer getProductType() {
		return productType;
	}

	public void setProductType(Integer productType) {
		this.productType = productType;
	}

	public String getProductTypeName() {
		return productTypeName;
	}

	public void setProductTypeName(String productTypeName) {
		this.productTypeName = productTypeName;
	}

	public Double getPrice() {
		return price;
	}

	public void setPrice(Double price) {
		this.price = price;
	}

	public Integer getQuantity() {
		return quantity;
	}

	public void setQuantity(Integer quantity) {
		this.quantity = quantity;
	}

	public Double getAmount() {
		return amount;
	}

	public void setAmount(Double amount) {
		this.amount = amount;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "OrderItem{" +
			"id=" + id +
			", orderNo=" + orderNo +
			", pid=" + pid +
			", productModel=" + productModel +
			", productType=" + productType +
			", price=" + price +
			", quantity=" + quantity +
			", amount=" + amount +
			"}";
	}
}
